﻿@model zichan.Entity.Asset
@{
    ViewBag.Title = "详情";
}

@section Pagetitle{
    @AdminCommon.PageTitle("详情", "编辑")
}
@section header{
    <style>
        .control-label {
            text-align: right;
        }
    </style>
}
<div class="portlet-body form">
    <div class="form-body">
        @*<h2 class="margin-bottom-20"> 资产详情 </h2>*@
        <div class="row">
            <div class="col-md-6">
                <h3 class="form-section">  基本信息</h3>
                <div class="row">
                    <div class="form-group">
                        <label class="control-label col-md-3">资产分类:</label>
                        <div class="col-md-9">
                            @Model.AssetClassName
                        </div>
                    </div>
                </div>
                <!--/span-->
                <div class="row">
                    <div class="form-group">
                        <label class="control-label col-md-3">所属公司:</label>
                        <div class="col-md-9">
                            @Model.CompanyName
                        </div>
                    </div>
                </div>
                <!--/span-->
                <div class="row">
                    <div class="form-group">
                        <label class="control-label col-md-3">资产名称:</label>
                        <div class="col-md-9">
                            @Model.Name
                        </div>
                    </div>
                </div>

                <div class="row">
                    <div class="form-group">
                        <label class="control-label col-md-3">资产编号:</label>
                        <div class="col-md-9">
                            @Model.Code
                        </div>
                    </div>
                </div>
                <!--/row-->
                <div class="row">
                    <div class="form-group">
                        <label class="control-label col-md-3">采购人:</label>
                        <div class="col-md-9">
                            @Model.BuyerName
                        </div>
                    </div>
                </div>
                <!--/span-->
                <div class="row">
                    <div class="form-group">
                        <label class="control-label col-md-3">采购时间:</label>
                        <div class="col-md-9">
                            @Model.BuyTime.ToShortDateString()
                        </div>
                    </div>
                </div>
                <!--/span-->
                <!--/row-->
                <div class="row">
                    <div class="form-group">
                        <label class="control-label col-md-3">资产所在地:</label>
                        <div class="col-md-9">
                            @Model.CalculatedGround
                        </div>
                    </div>
                </div>
                <div class="row">
                    <div class="form-group">
                        <label class="control-label col-md-3">接收人:</label>
                        <div class="col-md-9">
                            @Model.Recipient
                        </div>
                    </div>
                </div>
                <div class="row">
                    <div class="form-group">
                        <label class="control-label col-md-3">供应商:</label>
                        <div class="col-md-9">
                            @Model.Supplier
                        </div>
                    </div>
                </div>
                <div class="row">
                    <div class="form-group">
                        <label class="control-label col-md-3">备注:</label>
                        <div class="col-md-9">
                            @Model.Remark
                        </div>
                    </div>
                </div>
                <div class="row">
                    <div class="form-group">
                        <div class="col-md-offset-3 col-md-9">
                            <a href="javascript:if(confirm('确定要删除@(Model.Name)?'))location='/Assetes/delete?id=@Model.Id'" class="btn green">删除</a>
                            <a href="/Assetes/Index" class="btn default">返回</a>
                        </div>
                    </div>
                </div>
            </div>
            @if (Model.AssetClassId == 1 && zichan.Common.PowerHelp.Check("Assetes", "editServerPart_ImproveInformation"))
            {
                @Html.Action("editServerPart_ImproveInformation", new { id = Model.Id })
            }
            @if(Model.AssetClassId!=1&& zichan.Common.PowerHelp.Check("Assetes", "editPart_ImproveInformation"))
            {
                @Html.Action("editPart_ImproveInformation", new { assetId = Model.Id })
            }
        </div>
        @if (zichan.Common.PowerHelp.Check("UsageLog", "Index"))
        {<div class="row">
            @Html.Action("Index", "UsageLog", new { id = Model.Id })
        </div>}
    </div>
</div>
@section footer{
    @Scripts.Render("~/bundles/jqueryval")
}